package com.fs.iot.service;

import com.fs.common.base.service.BaseService;
import com.fs.iot.bean.dto.DeviceSimulationDTO;
import com.fs.iot.bean.query.DeviceSimulationQuery;

import java.util.Optional;

/**
 * 模拟设备服务接口 
 * @author Coder Generator 2025-03-23 20:05:02 
 **/
public interface DeviceSimulationEntityService extends BaseService<DeviceSimulationDTO, DeviceSimulationQuery> {
    default Optional<DeviceSimulationDTO> findByCode(String deviceCode) {
        return this.queryBuilder().eq("device_code", deviceCode)
                .query()
                .stream().findAny();
    }
}